package com.smart.community.property.dto;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;
import java.math.BigDecimal;
import java.time.LocalDate;

/**
 * 物业公司数据传输对象
 * @author Wu.Liang
 * @since 2025-06-29
 */
@Data
@Schema(description = "物业公司数据传输对象")
public class PropertyCompanyDTO {
    
    @Schema(description = "物业公司ID")
    private Long id;
    
    @Schema(description = "公司编码（由系统自动生成）", required = false)
    @Size(max = 50, message = "公司编码长度不能超过50个字符")
    private String companyCode;
    
    @Schema(description = "公司名称", required = true)
    @NotBlank(message = "公司名称不能为空")
    @Size(max = 100, message = "公司名称长度不能超过100个字符")
    private String companyName;
    
    @Schema(description = "公司地址")
    @Size(max = 255, message = "公司地址长度不能超过255个字符")
    private String address;
    
    @Schema(description = "联系电话")
    @Pattern(regexp = "^1[3-9]\\d{9}$", message = "联系电话格式不正确")
    private String contactPhone;
    
    @Schema(description = "联系邮箱")
    @Email(message = "联系邮箱格式不正确")
    @Size(max = 100, message = "联系邮箱长度不能超过100个字符")
    private String contactEmail;
    
    @Schema(description = "联系人")
    @Size(max = 50, message = "联系人长度不能超过50个字符")
    private String contactPerson;
    
    @Schema(description = "服务热线")
    @Pattern(regexp = "^(1[3-9]\\d{9}|0\\d{2,3}-?\\d{7,8}|400-?\\d{3}-?\\d{4}|800-?\\d{3}-?\\d{4})$", message = "服务热线格式不正确，支持手机号或常见热线号格式")
    private String serviceHotline;
    
    @Schema(description = "公司Logo")
    @Size(max = 255, message = "公司Logo长度不能超过255个字符")
    private String companyLogo;
    
    @Schema(description = "公司简介")
    private String introduction;
    
    @Schema(description = "营业时间")
    @Size(max = 100, message = "营业时间长度不能超过100个字符")
    private String businessHours;
    
    @Schema(description = "营业执照号")
    @Size(max = 50, message = "营业执照号长度不能超过50个字符")
    private String businessLicense;
    
    @Schema(description = "法定代表人")
    @Size(max = 50, message = "法定代表人长度不能超过50个字符")
    private String legalRepresentative;
    
    @Schema(description = "注册资本(万元)")
    private BigDecimal registeredCapital;
    
    @Schema(description = "成立日期")
    private LocalDate establishedDate;
    
    @Schema(description = "资质等级")
    @Size(max = 50, message = "资质等级长度不能超过50个字符")
    private String qualificationLevel;
    
    @Schema(description = "服务范围")
    private String serviceScope;
    
    @Schema(description = "状态：0-禁用，1-启用，2-待审核，3-审核拒绝")
    private Integer status;
    
    @Schema(description = "排序")
    private Integer sortOrder;
    
    @Schema(description = "收款账户")
    @Size(max = 100, message = "收款账户长度不能超过100个字符")
    private String paymentAccount;
    
    @Schema(description = "开户银行")
    @Size(max = 100, message = "开户银行长度不能超过100个字符")
    private String paymentBank;
    
    @Schema(description = "在线支付链接")
    @Size(max = 500, message = "在线支付链接长度不能超过500个字符")
    private String paymentLink;
    
    @Schema(description = "收款二维码图片URL")
    @Size(max = 500, message = "收款二维码图片URL长度不能超过500个字符")
    private String paymentQrCode;
    
    @Schema(description = "微信支付商户号")
    @Size(max = 50, message = "微信支付商户号长度不能超过50个字符")
    private String wechatPayMerchantId;
    
    @Schema(description = "支付宝商户号")
    @Size(max = 50, message = "支付宝商户号长度不能超过50个字符")
    private String alipayMerchantId;
} 